//===============================================================================
// Microsoft patterns & practices Enterprise Library Contribution
// Mapping Application Block
//===============================================================================

using System;
using System.ComponentModel;
using System.Drawing.Design;
using Microsoft.Practices.EnterpriseLibrary.Configuration.Design;
using Microsoft.Practices.EnterpriseLibrary.Configuration.Design.Validation;
using EntLibContrib.Common.Configuration.Design.Editors;
using EntLibContrib.Mapping.Properties;

namespace EntLibContrib.Mapping.Configuration.Design
{
	/// <summary>
	/// Represents a mapping using an Xml data file.
	/// </summary>
	public abstract class MapperNode : MapperBaseNode
	{
		#region Fields
		private string tableName;
		#endregion

		#region Properties
		/// <summary>
		/// Gets or sets the data transfer object table name.
		/// </summary>
		/// <value>The data transfer object table name for this node.</value>
		[MappingCategory("CategoryProvider")]
		[MappingDescription("MapperTableNameDescription")]
		public string TableName
		{
			get { return tableName; }
			set
			{
				if (value != null)
					tableName = value;
			}
		}
		#endregion

		#region Construction
		/// <summary>
		/// Initialize a new instance of the <see cref="MapperNode"/> class.
		/// </summary>
		protected MapperNode ()
		{
		}
		#endregion
	}
}